<?php
namespace app\user\event\subscribes\user;

use think\Event;
use app\user\event\listeners\user\Credit as CreditListener;
use app\user\event\listeners\user\CreditIncrease;
use app\user\event\listeners\user\CourseCredit;
use app\user\event\listeners\user\VipCredit;

class Credit
{
    public function subscribe(Event $event)
    {
        // 用户事件操作后添加积分事件
        $event->listen('AddCredit', CreditListener::class);

        // 用户充值产生的积分
        $event->listen('CreditIncrease', CreditIncrease::class);

        // 用户购买课程
        $event->listen('CourseCredit', CourseCredit::class);

        // 用户充值会员
        $event->listen('VipCredit', VipCredit::class);

    }
}
